Skip to content

🤖 feat: restore Orchestrator as hidden /orchestrate skill#3295

Open
ammar-agent wants to merge 2 commits into
mainfrom
orchestrate-skill
Open

🤖 feat: restore Orchestrator as hidden /orchestrate skill#3295
ammar-agent wants to merge 2 commits into
mainfrom
orchestrate-skill

Conversation

@ammar-agent
Copy link
Copy Markdown
Collaborator

@ammar-agent ammar-agent commented May 16, 2026

Summary

Restores the delegate-first orchestration workflow that was deleted in #3224 as an unadvertised built-in agent skill. Users who miss the original Orchestrator can type /orchestrate <request> to load the playbook into the conversation; the skill stays out of the default system-prompt skill index so it doesn't clutter the UX for users who don't miss it.

Also pulls the ChatInput placeholder tip carousel from side-questions-2hr3 ahead of that branch landing, with a tip surfacing /orchestrate so users have a passive discovery path for the new hidden skill.

Background

#3224 ripped out the Orchestrator agent wholesale because the scaffolding around it (LLM auto-router, settings UI, agent picker entry, post-propose_plan button, two helper methods on taskService) carried real maintenance cost. The original PR explicitly chose not to migrate users.

But the primitives Orchestrator orchestrated all remained:

  • task / task_await / task_list / task_terminate (toolDefinitions.ts:2181, 2289)
  • task_apply_git_patch (toolDefinitions.ts:1449)
  • sub-agent patch artifact flow + git am integration
  • Max Task Nesting Depth setting

So the workflow itself never broke — only the prompt and the chrome that pointed agents toward it. A markdown skill is enough to put the workflow back without resurrecting the scaffolding.

Implementation

Orchestrate skill

  • src/node/builtinSkills/orchestrate.md — adapted from the deleted orchestrator.md (recovered from e623bb8af^). Frontmatter sets advertise: false. Body keeps the original sections: delegate-first hard rules, delegation guide (explore / exec / plan / desktop), task brief template, dependency analysis, parallel + sequential patch integration loops, conflict reconciliation playbook (including the git am --abort-only-when-in-progress nuance), and the "never read session storage" guardrail. Adds a prerequisites note about Max Task Nesting Depth.
  • builtInSkillContent.generated.ts — regenerated via bun scripts/gen_builtin_skills.ts.
  • agentSkillsService.test.ts — two existing assertions enumerate the built-in skill list; both now include "orchestrate".
  • builtInOrchestrateSkill.test.ts — new focused test confirms the skill is registered, has advertise: false, and its body still carries the load-bearing directives (regex spot-checks on delegate-first, task_apply_git_patch, dry-run, Max Task Nesting Depth) — wording can drift, but a wholesale gutting of the playbook would fail.

Tip carousel (pulled forward from side-questions-2hr3)

  • src/browser/features/ChatInput/placeholderTips.ts — rotating placeholder tip list keyed off a wall-clock 20-minute bucket, so switching workspaces mid-bucket never reshuffles the visible tip. Includes the /orchestrate tip alongside /btw, /haiku, /+high, /compact, /fork, /plan, /goal, /clear --soft, /new, /vim, /truncate.
  • src/browser/features/ChatInput/placeholderTips.test.ts — covers single-bucket stability, bucket-boundary rotation, modulo wrap, degenerate-input fallback, and /orchestrate presence.
  • src/browser/features/ChatInput/index.tsx — workspace variant uses getPlaceholderTip() instead of "Type a message..." on non-mobile; mobile keeps the plain placeholder because the on-screen keyboard already squeezes the input.

What this PR intentionally does not restore

  • Tool restriction. The old agent did tools.remove: [file_edit_.*] so it physically could not edit files. A skill can't strip tools from its caller. The skill prose enforces the rule strongly ("Do not implement features/bugfixes directly in this workspace") but it's a soft constraint.
  • "Start Orchestrator" button on propose_plan cards and the planExecutorRouter LLM auto-router. Recreating those is a separate, scaffolding-heavy feature; users who want the post-plan handoff can type /orchestrate Implement the plan. themselves.
  • Distinct agent picker entry / Workflow icon. Users stay in their current agent (Exec); the chrome was incidental.

This is the same hidden-skill pattern already documented for /deep-review in docs/agents/agent-skills.mdx.

Validation

  • bun test src/node/services/agentSkills/ — 36/36 pass.
  • bun test src/node/services/tools/agent_skill_{read,read_file,list}.test.ts src/node/services/tools/skills_catalog_read.test.ts — 89/89 pass alongside the skill suite.
  • bun test src/browser/features/ChatInput/placeholderTips.test.ts — 5/5 pass.
  • make static-check — green.

Risks

Low. No schema changes, no IPC changes, no migrations. Behavioral surface:

  1. One additional unadvertised built-in skill is discoverable. agentSkills.list already returns unadvertised skills, so slash autocomplete surfaces /orchestrate once the user starts typing it, matching the documented behavior of unadvertised skills.
  2. The workspace ChatInput placeholder is no longer the static string "Type a message..." on desktop. The text rotates every 20 minutes against a wall-clock bucket; the value is deterministic per bucket so tests / screenshots inside a single bucket are stable.

The legacy config keys (planSubagentExecutorRouting, planSubagentDefaultsToOrchestrator) deliberately removed in #3224 are not reintroduced.


Generated with mux • Model: anthropic:claude-opus-4-7 • Thinking: high • Cost: $11.13

@ammar-agent
Copy link
Copy Markdown
Collaborator Author

@codex review

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 145b3882e9

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/builtinSkills/orchestrate.md
@ammar-agent
Copy link
Copy Markdown
Collaborator Author

@codex review

Replied + resolved the autocomplete thread — keeping /orchestrate discoverable in autocomplete is intentional (advertise=false is about the system-prompt skill index, not user-facing surfaces). No code changes since last review.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 145b3882e9

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/node/builtinSkills/orchestrate.md
@ammar-agent
Copy link
Copy Markdown
Collaborator Author

@codex review

Replied + resolved the ACP thread — same reasoning as before: the ACP filter for unadvertised skills is system-wide existing behavior, not specific to /orchestrate. Changing it would be an orthogonal scope. No code changes since last review.

@chatgpt-codex-connector
Copy link
Copy Markdown

Codex Review: Didn't find any major issues. More of your lovely PRs please.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ammar-agent
Copy link
Copy Markdown
Collaborator Author

@codex review

Pulled the placeholder tip carousel forward from side-questions-2hr3 (likely to land after this PR) and added a tip surfacing /orchestrate so the unadvertised skill has a passive discovery path.

New files:

  • src/browser/features/ChatInput/placeholderTips.ts
  • src/browser/features/ChatInput/placeholderTips.test.ts

Wired in src/browser/features/ChatInput/index.tsx (non-mobile only — mobile keeps the static "Type a message..." placeholder).

Reintroduces the delegate-first orchestration workflow that was deleted
in #3224 ("rip out the Orchestrator agent feature") as an unadvertised
built-in skill, invocable via /orchestrate.

The original agent was removed because the surrounding scaffolding (LLM
auto-router, settings UI, picker entry, plan-handoff button) had a high
maintenance cost. The underlying primitives it orchestrated — task /
task_await / task_apply_git_patch — were left in place, so a markdown
skill is sufficient to recover the workflow with zero new scaffolding.

advertise: false keeps the skill out of the system-prompt skill index
(uncluttered default UX), while users who miss it can still type
/orchestrate to load the playbook on-demand. Mirrors the existing
hidden-skill pattern documented for /deep-review.
Pull the placeholder tip carousel from side-questions-2hr3 ahead of that
branch landing, and add a tip surfacing /orchestrate alongside the
existing slash-command tricks. The skill is unadvertised in the
system-prompt skill index (advertise: false), so the carousel is one of
the few passive discovery surfaces users will see it on.

Wall-clock 20-minute bucket means switching workspaces mid-bucket never
reshuffles the visible tip. Mobile keeps the plain 'Type a message...'
placeholder because the on-screen keyboard squeezes the input.

Generated with mux • Model: anthropic:claude-opus-4-7 • Thinking: high
@chatgpt-codex-connector
Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant